home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The Atari Compendium
/
The Atari Compendium (Toad Computers) (1994).iso
/
files
/
umich
/
falcon
/
programm.ing
/
nt_dsp1.lzh
/
NT_DSP1.MSA
/
FNTNS
/
EXP2.HLP
< prev
next >
Wrap
Text File
|
1989-01-24
|
783b
|
25 lines
Name: EXP2.ASM
Type: Assembler Macro
Version: 1.0
Last Change: 26-Jan-87
This macro will take the exponential of a number base 2.
2**(x) = .1713425 x*x + .6674432 x + .9979554
This polynomial will give approximately 8 significant bits of accuracy.
This is valid for -1<= x <=0.
The input value is put into x0, the output value is returned in register
A. Register R1 initially points to the coefficients in y memory in the
order:a1,a2,a0.
R1
|
v
y:.6674432,.1713425,.9979554
a1 a2 a0
Benchmarks for this macro is 4 cycles, 4 instructions.
The library program EXP2T demonstrates how to use the EXP2 macro.